﻿<%@ Page Title="" Language="C#" MasterPageFile="~/adm_vlg/Admin_master.master" AutoEventWireup="true" ValidateRequest="false"
    CodeFile="faqEdit.aspx.cs" Inherits="adm_vlg_faqEdit" %>

<asp:Content ID="Content1" ContentPlaceHolderID="head" runat="Server">
</asp:Content>
<asp:Content ID="Content2" ContentPlaceHolderID="content" runat="Server">
    <div class="image">
        <img src="img/icon-48-category.png" /></div>
    <div class="text">
        QUẢN LÝ DANH MỤC <span style="font-size: 14px">[
            <asp:Literal ID="ltr_action_name" runat="server"></asp:Literal>
            ]</span></div>
    <div class="adminform" style="padding: 10px;">
        <asp:Button ID="butt_save" runat="server" OnClick="butt_save_Click" Text="Lưu"  OnClientClick="return check()"/>
        <asp:HiddenField ID="hid" runat="server" />
        <asp:HiddenField ID="hd_cat_display_type" runat="server" />
    </div>
    <fieldset class="adminform">
        <legend>Chi tiết</legend>
        <table class="admintable" style="width: 100%">
            <tr>
                <td>
                    Loại
                </td>
                <td>
                    <asp:DropDownList runat="server" ID="ddlType">
                        <asp:ListItem Value="-1" Text="--Chọn nhóm câu hỏi--"></asp:ListItem>
                        <asp:ListItem Value="0" Text="Người mua"></asp:ListItem>
                        <asp:ListItem Value="1" Text="Người bán"></asp:ListItem>
                    </asp:DropDownList>
                </td>
            </tr>
            <tr>
                <td>
                    <b>Câu hỏi</b>
                </td>
                <td>
                    <asp:TextBox  Width="100%" runat="server" TextMode="MultiLine"
                        Rows="5" ID="txtQuestion"></asp:TextBox>
                </td>
            </tr>
            <tr>
                <td>
                    <b>Trả lời</b>
                </td>
                <td>
                    <asp:TextBox CssClass="txtContent" Width="100%" runat="server" TextMode="MultiLine"
                        Rows="5" ID="txtAnswer"></asp:TextBox>
                </td>
            </tr>
        </table>
    </fieldset>
    <div class="adminform" style="padding: 10px;">
        <asp:Button ID="butt_save0" runat="server" OnClick="butt_save_Click" Text="Lưu" OnClientClick="return check()" />
    </div>
    <script type="text/javascript">
        $(function () {
            MCE($(".txtContent"));
            $(".message_system").fadeOut("slow");

        })
        function check() {
            var ddlValue = $("#<%=ddlType.ClientID %>").val();
            if (ddlValue == -1) {
                alert("Chọn loại faq");
                $("#<%=ddlType.ClientID %>").focus();
                return false;
            }
            else return true;
        }
    </script>
</asp:Content>
